
function main(doc, ctx) {   //jsoup syntax
	var db = ctx.db;
	var all = doc.select('text.tyc-num'); 
	var res = [];
	for(var i in all){
		var e = all[i];
		print(e.text())
		continue;
		var logo = e.selectFirst("span.text").text(); 
		print(logo); 
	}
	
	if(res.length > 0) {
		//db.batchInsert('quote', res);
	}
	
	var e = doc.selectFirst("li >a.-current"); 
	if(e){ 
		e = e.parent().nextElementSibling();  
		if(e) { 
			e = e.selectFirst(">a")
			return [e.attr("href")]; 
		}
	} 
} 
 